CC = gcc
CXX = g++
AR =ar 

#CXXFLAGS  := -fPIC -w -g -D_DEBUG -lrt
CXXFLAGS  := -fPIC -w

OBJ := $(patsubst %.cpp,%.o,$(wildcard *.cpp))
OBJ += $(patsubst %.c,%.o,$(wildcard ./*.c))

INCLUDE  =  -I./ -I../
SHLIBS = ./libhsctu_guomi_vpn.so

TARGETNAME = test

$(TARGETNAME):$(OBJ) 
	$(CXX) $^  $(SHLIBS) -lpthread -o test 

%.o : %.cpp
	 $(CXX) $(CXXFLAGS) -c $< -o $@ $(INCLUDE)
%.o : %.c
	$(CC) $(CXXFLAGS) -c $< -o $@ $(INCLUDE) 
	
clean:
	rm -rf $(OBJ) $(TARGETNAME)

